package view;

import java.awt.Dimension;

import javax.swing.JLabel;

import model.SVG;

// Extend a JLabel, ultimately thats what it is
public class StatusBar extends JLabel {

    /**
	 * 
	 */
    private static final long serialVersionUID = 4581481133323037177L;
    private SVG model = SVG.getSingletonInstance(); // give it the singleton
						    // instance

    public StatusBar() {
	setPreferredSize(new Dimension(0, 16)); // nice size fits perfectly
	setText("Please open a file"); // default text
    }

    public void refresh() {
	setText(" File: " + model.getFilename() + " | Width: "
		+ model.getWidth() + " | Height: " + model.getHeight());

    }

}
